﻿using System;
using System.Windows.Forms;

namespace GatherHelper
{
    public partial class SettingsForm : Form
    {
        public SettingsForm()
        {
            InitializeComponent();
        }

        private void SettingsForm_Load(object sender, EventArgs e)
        {
            pgSettings.SelectedObject = GatherHelperSettings.Instance;
        }

        private void pgSettings_PropertyValueChanged(object s, PropertyValueChangedEventArgs e)
        {
            var gatherHelperSettings = pgSettings.SelectedObject as GatherHelperSettings;
            if (gatherHelperSettings != null)
                gatherHelperSettings.Save();
        }
    }
}
